package com.xinz.activity;

import com.xinz.Constants;
import com.xinz.common.Connector;
import com.xinz.shared.player.PlayerInterface;

import android.os.Bundle;

public class SpotActivity extends BaseActivity{

	String account;
	String password;
	
	PlayerInterface playerServer;
	
	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		
		account = getIntent().getStringExtra(Constants.ACCOUNT);
		password = getIntent().getStringExtra(Constants.PASSWORD);
		
		new Thread(new Runnable() {
			@Override
			public void run() {
				playerServer = Connector.getImplement(PlayerInterface.class);
			}
		}).start();
		try {
			Thread.sleep(3000);
		} catch (InterruptedException e) {
			e.printStackTrace();
		}
		playerServer.login(account, password);
	}
}
